package com.his.his_system.domain;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import java.io.Serializable;
import java.math.BigDecimal;
import lombok.Data;

/**
 * 挂号费用子表
 * @TableName dzm_his_registeredfee_sub
 */
@TableName(value ="dzm_his_registeredfee_sub")
@Data
public class DzmHisRegisteredfeeSub implements Serializable {
    /**
     * 
     */
    @TableId(type = IdType.AUTO)
    private Integer regSubId;

    /**
     * 挂号费用ID
     */
    private Integer regId;

    /**
     * 挂号费用子名称
     */
    private String subRegisteredfeeName;

    /**
     * 子费用 
     */
    private BigDecimal subRegisteredfeeFee;

    @TableField(exist = false)
    private static final long serialVersionUID = 1L;

    @Override
    public boolean equals(Object that) {
        if (this == that) {
            return true;
        }
        if (that == null) {
            return false;
        }
        if (getClass() != that.getClass()) {
            return false;
        }
        DzmHisRegisteredfeeSub other = (DzmHisRegisteredfeeSub) that;
        return (this.getRegSubId() == null ? other.getRegSubId() == null : this.getRegSubId().equals(other.getRegSubId()))
            && (this.getRegId() == null ? other.getRegId() == null : this.getRegId().equals(other.getRegId()))
            && (this.getSubRegisteredfeeName() == null ? other.getSubRegisteredfeeName() == null : this.getSubRegisteredfeeName().equals(other.getSubRegisteredfeeName()))
            && (this.getSubRegisteredfeeFee() == null ? other.getSubRegisteredfeeFee() == null : this.getSubRegisteredfeeFee().equals(other.getSubRegisteredfeeFee()));
    }

    @Override
    public int hashCode() {
        final int prime = 31;
        int result = 1;
        result = prime * result + ((getRegSubId() == null) ? 0 : getRegSubId().hashCode());
        result = prime * result + ((getRegId() == null) ? 0 : getRegId().hashCode());
        result = prime * result + ((getSubRegisteredfeeName() == null) ? 0 : getSubRegisteredfeeName().hashCode());
        result = prime * result + ((getSubRegisteredfeeFee() == null) ? 0 : getSubRegisteredfeeFee().hashCode());
        return result;
    }

    @Override
    public String toString() {
        StringBuilder sb = new StringBuilder();
        sb.append(getClass().getSimpleName());
        sb.append(" [");
        sb.append("Hash = ").append(hashCode());
        sb.append(", regSubId=").append(regSubId);
        sb.append(", regId=").append(regId);
        sb.append(", subRegisteredfeeName=").append(subRegisteredfeeName);
        sb.append(", subRegisteredfeeFee=").append(subRegisteredfeeFee);
        sb.append(", serialVersionUID=").append(serialVersionUID);
        sb.append("]");
        return sb.toString();
    }
}